<?php


namespace app\admin\validate;


use think\Validate;

class Shop extends Validate
{
    /**
     * 验证规则
     * @var string[]
     */
    protected $rule = [
        'shopId' => 'require',
        'shopName' => 'require|max:50|min:1',
        'shopPhone' => 'require',
        'shopOwner' => 'require',
        'type' => 'require',
        'typeName' => 'require',
        'shopMobile' => 'require|number|max:11|min:11|mobile',
        'marketId' => 'require',
        'marketName' => 'require',
        'regionId' => 'require',
        'area' => 'require',
        'status' => 'require',
        'province_id' => 'require',
        'city_id' => 'require',
        'country_id' => 'require',
        'address' => 'require',
        'keycode' => 'require',
        'sex' => 'require',
        'password' => 'require',
        'start_time' => 'require',
        'end_time' => 'require',
        'monthly_fee' => 'require',
        'bed_num' => 'require',
    ];
    /**
     * 场景
     * @var string[][]
     */
    protected $scene = [
        'create' => ['shopName', 'shopPhone', 'shopOwner', 'type', 'typeName', 'marketName', 'shopMobile', 'monthlyFee', 'bedNum', 'password'],
        'update' => ['shopId','shopMobile','sex'],
    ];
    /**
     * @var array
     */
    protected $message = [

    ];

}